using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;

namespace CUCTV
{
    public partial class OpenUrl : Form
    {
        private mainForm m_Parent = null;
       // private CUCTV_DS m_Parent_ds = null;
        public OpenUrl(mainForm parentForm)
        {
            InitializeComponent();
            this.m_Parent = parentForm;
        }

        //public OpenUrl(CUCTV_DS parentForm)
        //{
        //    InitializeComponent();
        //    this.m_Parent_ds = parentForm;
        //}

        private void btnOK_Click(object sender, EventArgs e)
        {

            if (this.m_Parent != null)
            {
                this.m_Parent.Player.URL = tbUrl.Text;
                this.Close();
                this.Dispose();
            }
            //if (this.m_Parent_ds != null)
            //{
            //    this.m_Parent_ds.ClipFile = tbUrl.Text;
            //    this.m_Parent_ds.PlayClip();
            //    this.Close();
            //    this.Dispose();
            //}
        }

        private void btnCancel_Click(object sender, EventArgs e)
        {
            this.Close();
            this.Dispose();
        }
    }
}